package com.ryskoo.catering.cart.dto;

import com.ryskoo.catering.coupondetail.domain.CouponDetailPO;

/**
 * 购物车明细
 * @author BeHappy
 */
public class CartDetailDTO {

    //商品uuid
    private String productUuid;

    //商品名称
    private String productName;

    //购买数量
    private int buyNum;

    //规格uuid
    private String skuUuid;

    //规格名称
    private String showName;

    //单个商品赠送积分
    private int integral;

    //商品价格
    private double productPrice;

    //总价格productPrice*buyNum
    private double totalPrice;

    //商品图片（小图）
    private String image;

    //单个商品餐盒费用
    private double lunchboxPrice;

    /**
     * 单品优惠券明细Uuid
     */
    private String couponDetailUuid;

    /**
     * 优惠券优惠金额
     */
    private double couponPrice;

    //单品优惠券
    private CouponDetailPO couponDetail;

    public String getProductUuid() {
        return productUuid;
    }

    public void setProductUuid(String productUuid) {
        this.productUuid = productUuid;
    }

    public String getProductName() {
        return productName;
    }

    public void setProductName(String productName) {
        this.productName = productName;
    }

    public int getBuyNum() {
        return buyNum;
    }

    public void setBuyNum(int buyNum) {
        this.buyNum = buyNum;
    }

    public String getSkuUuid() {
        return skuUuid;
    }

    public void setSkuUuid(String skuUuid) {
        this.skuUuid = skuUuid;
    }

    public String getShowName() {
        return showName;
    }

    public void setShowName(String showName) {
        this.showName = showName;
    }

    public int getIntegral() {
        return integral;
    }

    public void setIntegral(int integral) {
        this.integral = integral;
    }

    public double getProductPrice() {
        return productPrice;
    }

    public void setProductPrice(double productPrice) {
        this.productPrice = productPrice;
    }

    public double getTotalPrice() {
        return totalPrice;
    }

    public void setTotalPrice(double totalPrice) {
        this.totalPrice = totalPrice;
    }

    public String getImage() {
        return image;
    }

    public void setImage(String image) {
        this.image = image;
    }

    public double getLunchboxPrice() {
        return lunchboxPrice;
    }

    public void setLunchboxPrice(double lunchboxPrice) {
        this.lunchboxPrice = lunchboxPrice;
    }

    public CouponDetailPO getCouponDetail() {
        return couponDetail;
    }

    public void setCouponDetail(CouponDetailPO couponDetail) {
        this.couponDetail = couponDetail;
    }

    public String getCouponDetailUuid() {
        if(null != this.couponDetail){
            return this.couponDetail.getUuid();
        }
        return couponDetailUuid;
    }

    public void setCouponDetailUuid(String couponDetailUuid) {
        this.couponDetailUuid = couponDetailUuid;
    }

    public double getCouponPrice() {
        if(null != this.couponDetail){
            return this.couponDetail.getCouponPrice();
        }
        return couponPrice;
    }

    public void setCouponPrice(double couponPrice) {
        this.couponPrice = couponPrice;
    }
}
